from google.appengine.ext import db;


class Contact(db.Model):
    owner = db.UserProperty(required=True)
    friend = db.UserProperty()
    
    name = db.StringProperty()
    email = db.StringProperty()


class Event(db.Model):
    contact = db.ReferenceProperty(Contact)
    
    owner = db.UserProperty(required=True)
    
    type = db.StringProperty()

    is_precise = db.BooleanProperty()    
    date = db.DateProperty()
    precise_date = db.DateTimeProperty()


class Wish(db.Model):
    event = db.ReferenceProperty(Event)
    
    owner = db.UserProperty(required=True)
    
    wish = db.StringProperty(multiline=True)    
    language = db.StringProperty()